package com.xxx.string;

/**
 * @version v1.0
 * @Description:
 * @Author zhanzhongxin
 * @Date 2021/7/16 16:05
 * @Copyright 博为峰
 */
public class StringDemo01 {
    public static void main(String[] args) {
        /*
           String类特点 Strings are constant; their values cannot be changed after they are created
                       字符串常量，值在创建后不能改变

           1.构造方法
           String(byte[] bytes)  字节数组->字符串
           String(char[] value)  字符数组->字符串
         */
        
        //ctrl + alt + m 2次
        byte[] bytes = new byte[]{96, 97, 98, 99};
        char[] chars = {'a', 'b', 'c'};
        String s1 = new String(chars);
        System.out.println(s1);


//        System.out.println('你'+0);
//        System.out.println('A' + 0);

        /*
          字符编码
         */
    }
}
